from selenium.webdriver.common.by import By

from common.pagebase import Base

# 登录
class Login(Base):
    def login(self):
        # self.driver.find_element(By.XPATH,"//input[@placeholder='请输入用户名']").send_keys("107644")
        # self.driver.find_element(By.XPATH,'//input[@placeholder="请输入密码"]').send_keys("Wfx107644")
        # self.driver.find_element(By.XPATH,"//button[@class='el-button login-btn el-button--primary']").click()
        self.base_send(By.XPATH, "//input[@placeholder='请输入用户名']", "107644")
        self.base_send(By.XPATH, '//input[@placeholder="请输入密码"]', "Wfx107644")
        self.base_click(By.XPATH, "//button[@class='el-button login-btn el-button--primary']")
        return self